home *** CD-ROM | disk | FTP | other *** search
/ Adobe Graphics & Publishing SDK 1996 December / Adobe Graphics & Publishing SDK 1996 December.iso / pc / pm65sdk / sourcecode / pagemakerclasslibrary / commands / ptrapsettings.cpp < prev    next >
Encoding:
C/C++ Source or Header  |  1996-08-15  |  1.4 KB  |  58 lines

  1. /*
  2.  *--- PTrapSettings.cpp ---------------------------------------------------
  3.  * Copyright (c) 1995-96 Adobe Systems Incorporated.  All rights reserved.
  4.  * Created on Sun, Oct 22, 1995 @ 4:19 PM by Paul Ferguson.
  5.  *
  6.  * Description:  For notes about this class, refer to the
  7.  * PCL documentation file PTrapSettings.html
  8.  *-------------------------------------------------------------------------
  9.  */
  10.  
  11. #include "PTrapSettings.h"
  12. #include "PGetTrapSettings.h"
  13. #include "PRequestBuf.h"
  14. #include "PCommand.h"
  15.  
  16. const size_t REQUEST_SIZE = 18;
  17.  
  18. PTrapSettings::PTrapSettings
  19.   (    short    bEnable,
  20.     long    xDefWidth,
  21.     long    xBlackWidth,
  22.     short    dStepLimit,
  23.     short    dCentThresh,
  24.     short    dTextLimit,
  25.     short    bTrapOverImp )
  26. {
  27.     char * temp[REQUEST_SIZE];
  28.     PRequestBuf request(temp);
  29.  
  30.     request << bEnable
  31.             << xDefWidth
  32.             << xBlackWidth
  33.             << dStepLimit
  34.             << dCentThresh
  35.             << dTextLimit
  36.             << bTrapOverImp;
  37.             
  38.     PCommand command(pm_trapsettings, request);
  39. }
  40.  
  41. PTrapSettings::PTrapSettings(const PGetTrapSettings& trapSettings)
  42. {
  43.     char * temp[REQUEST_SIZE];
  44.     PRequestBuf request(temp);
  45.  
  46.     request << (short) trapSettings.bEnable
  47.             << trapSettings.xDefWidth
  48.             << trapSettings.xBlackWidth
  49.             << trapSettings.dStepLimit
  50.             << trapSettings.dCentThresh
  51.             << trapSettings.dTextLimit
  52.             << (short) trapSettings.bTrapOverImp;
  53.             
  54.     PCommand command(pm_trapsettings, request);
  55. }
  56.  
  57. // end of PTrapSettings.cpp
  58.